-- GENERATED SPELL FOR [Cursed Lost One] --


function spell0_17115(pUnit, Event) --@Curse of Agony,n/a--
pUnit:FullCastSpellOnTarget(14868,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17115', 30000, 1)
end

function spell1_17115(pUnit, Event) --@Disarm,n/a--
pUnit:FullCastSpellOnTarget(6713,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_17115', 5334, 1)
end

function Sorts_17115(pUnit, Event)
local choix_sorts_17115 = math.random(0, 1)
if choix_sorts_17115 == 0 then
pUnit:RegisterEvent('spell0_17115', 1, 1)
end
if choix_sorts_17115 == 1 then
pUnit:RegisterEvent('spell1_17115', 1, 1)
end
end

function mob17115_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_17115', math.random(1500, 3000), 1)
end

function mob17115_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17115_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob17115_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(17115, 1, 'mob17115_Action')
RegisterUnitEvent(17115, 2, 'mob17115_Leave')
RegisterUnitEvent(17115, 3, 'mob17115_Kill')
RegisterUnitEvent(17115, 4, 'mob17115_Die')
